package com.xframe.domain.sys;


import com.xframe.domain.BaseModel;
import com.xframe.xdal.core.DataBaseAccess;
import com.xframe.xdal.core.annotation.*;
import com.xframe.xdal.core.constant.AutoFillType;
import com.xframe.xdal.core.model.ConditionValue;
import com.xframe.xdal.core.model.FindOptions;
import com.xframe.xdal.core.model.IModelMapKey;
import com.xframe.xdal.core.model.Operator;
import lombok.Data;
import lombok.experimental.Accessors;

import java.util.List;
import java.util.Map;

/**
 * @Description: 值列表清单
 * @ClassName: com.xframe.domain.sys.SysValueDetail
 * @Author: xufeng
 * @CreateTime: 2023/4/3 18:38
 **/
@Data
@Accessors(chain = true)
@XTable(value = "sys_value_details", label = "值列表清单")
@XBelongsTo(typeName = "com.xframe.domain.sys.SysValueDic",foreignKey = "valCode", targetKey = "valCode",as = "refValueDic")
@XSelectItem(keyName = "val",codeName = "val",textName = "text")
public class SysValueDetail extends BaseModel {
    /**
     * 主键
     */
    @AutoFill(AutoFillType.Snowflake)
    @XColumn(name = "val_detail_id", primaryKeyFlag = true,desc = "主键")
    private Long valDetailId;

    /**
     * 值列表编码
     */
    @XQueryCondition
    @XColumn(name = "val_code", length = 50,desc = "值列表编码",uniqueFlag = true)
    private String valCode;

    /**
     * 值
     */
    @XQueryCondition
    @XColumn(name = "val", length = 50,desc = "值",uniqueFlag = true)
    private String val;

    /**
     * 文本
     */
    @XGridTableRef
    @XColumn(name = "text", length = 200,desc = "文本")
    private String text;

    /**
     * 排序码
     */
    @AutoFill(defVal = "0")
    @XColumn(name = "order_no",desc = "排序码")
    private Integer orderNo;

    /**
     * 关联的主表信息
     */
    private SysValueDic refValueDic;



}
